home *** CD-ROM | disk | FTP | other *** search
/ QRZ! Ham Radio 8 / QRZ Ham Radio Callsign Database - Volume 8.iso / mac / files / dsp / dska_10.hqx / dska ƒ / dska.doc < prev    next >
Text File  |  1994-09-26  |  8KB  |  192 lines

  1. DSKA - a Macintosh based TMS3202x assembler
  2.  
  3. User Interface by Eric Brombaugh (ericb@sicom.com)
  4. version 1.0   9-26-94
  5. Assembler by Lloyd Miller ( lloyd@lfmcal.cuc.ab.ca)
  6. version 0.14
  7.  
  8. INTRO
  9. This program is a simple assembler for the Texas Instruments TMS3202x family
  10. of Digital Signal Processors.  It is intended for use with the program dskL by
  11. Gerrit Polder, which can be used to download the assembled code to the TI DSK
  12. development system.
  13.  
  14. USAGE
  15. The user interface is extremely simple.  To assemble a source file,  select your
  16. text file in the File->Open menu.  Then select File->Assemble.  A console I/O
  17. window will open indicating the progress of the assembly.  If there are errors,
  18. they will be listed in this window.  Successful assembly will be noted here as
  19. well.  If you have corrected errors, you may re-assemble the source text by
  20. choosing File->Assemble again, without first going to the File->Open menu.
  21.  
  22. The File->Preferences item allows you to customize the .xxx extension of your
  23. resulting binary output file and listing file.  The defaults are .dsk for the binary
  24. file, and .lst for the listing file.  You may also change the size (row, column) of
  25. the console I/O window.  Note that the contents of the console I/O window will
  26. be lost if you click OK in the preferences dialog.
  27.  
  28. The file type of both of the output files is 'TEXT', so they may be viewed with
  29. TeachText or SimpleText.  The Creator of the binary file has been set to dskL,
  30. which will allow you to load the binary file into Gerrit Polder's dskL application
  31. simply by double-clicking on the file in the Finder.
  32.  
  33. FILES
  34. The following files should be included with this archive:
  35.  
  36. 1)    DSKA                                The assembler application.
  37. 2)  dska.doc                        This documentation file.
  38. 3)  autotest.asm        Test code for the DSK board.
  39. 4)  hostspec.asm        A spectrum analyzer which plots on the host computer.
  40. 5)  mmregs.inc            An include file which defines symbols for the TMS320c26 registers.
  41. 6)  dsk_twid.inc        An include file which defines sine/cosines for an fft.
  42. 7)  TESTF.ASM                An assembler test file.
  43.  
  44. NOTES
  45. There are a few things about this program which could be better, command keys
  46. would be nice for instance but were left out because they conflict with the Think C
  47. console interface.  A nice help system would be good, but doesn't really add to
  48. the functionality.
  49.  
  50. If you have any bug-reports or problems with this application, please let me know.
  51. Don't bother Lloyd, as he cannot support the Macintosh version.
  52.  
  53. THANKS
  54. Thanks go to Lloyd Miller of course, for his clearly written assembler code.  This
  55. program would simply not exist without his original work.  Gerrit Polder helped
  56. immensely in the beta-test of this code, as well as providing motivation for
  57. doing it in the first place.
  58.  
  59. LEGAL
  60. This program is freeware.  Use it, but don't sell it.
  61.  
  62. Enjoy!
  63.  
  64. Eric Brombaugh
  65. ericb@sicom.com
  66. emeb@indirect.com
  67. Sept. 26, 1994
  68.  
  69. ADDITIONAL INFO
  70. The following are docs from Lloyd Miller pertaining to his dska.c assembler.  Since
  71. the Macintosh version of dska is based on his code, I have included it here.
  72. --------------------------------------------------------------------------
  73. Some random notes regarding the dska.c dsp starters kit assembler
  74. unofficial replacement I have created. This kinda assumes you have a TI
  75. DSP Starters' kit and you have tried to use their assembler.
  76.  
  77. Features this assembler has that the standard dska.exe that comes free
  78. with the DSK did not have:
  79.  
  80.  simple arithmetic expressions (+-*/ and ()s)
  81.  nested include files
  82.  nested .if/.else/.endif
  83.  free source code
  84.  Linux compatibility (actually general portability but I haven't tested
  85. it that much to make that claim)
  86.  second pass listing showing actual generated code offsets
  87.  
  88. Features this assembler lacks that the standard dska.exe had:
  89.  
  90. The command line option to define symbols.
  91.  
  92.  
  93.  
  94. To use this assembler, you will probably need to compile it yourself
  95. since I only give out source code. You have to link with the math
  96. library probably (-lm).
  97.  
  98. I compile it regularly on Linux with GCC and occasionally on MS-DOS
  99. with Borland's Turbo-C 2.0.
  100.  
  101. To run the assembler the command line is:
  102.  
  103.   dska source.asm binout.dsk listout.lst
  104.  
  105. The arguments are file names.
  106.   source.asm is your input file.
  107.   binout.dsk is the output binary in .dsk format just like the TI
  108. assembler
  109.   listout.lst is the output listing file much like the TI assembler but
  110. I think it is better
  111.  
  112. If you do not want one of the output files then use /dev/null (or NUL:
  113. on MS-DOS).
  114.  
  115. The .dsk binary file format is pretty stupid but we have to use it to be
  116. able to cooperate with the debugger and stuff.
  117.  
  118.  
  119. You should be able to use an expression combining numbers and symbols
  120. anywhere that you could use a number or a symbol before. The obvious
  121. exception is the dumb expressions as labels that TI tries to call a
  122. feature in their assembler. You can only have plain symbol names in the
  123. label positions of lines.
  124.  
  125. The colons (":") on labels are optional. Labels and only labels start
  126. in column one. Comments can also start in column one. Either a ";" or a
  127. "*" in column one makes the whole line into a comment. "*" not in
  128. column one will generally just be an error if it doen't make sense as a
  129. multiplication. Anything else must be preceded by a space or a tab.
  130. Labels must be separated from the operation field by a space or a tab.
  131.  
  132. The nasty restrictions they claim for the conditional assembly
  133. expression is of course totally relaxed.
  134.  
  135. I think you could use an external macro processor such as m4 but it
  136. would mean the line numbers wouldn't mean much any more. Perhaps someday
  137. the assembler could recognize embeded #line operations.
  138.  
  139. One place you cannot (yet) use expressions is the floating point values
  140. for the .qxx, .lqxx, .float, .double, .bfloat, and .efloat directives.
  141.  
  142. Ordinary labels cannot be redefined but labels on .set directives can be
  143. redefined at will.
  144.  
  145. Forward references are generally OK in the instruction operands and
  146. data lists but if you try hard enough you can get things confused
  147. between the values found for pass 1 and pass 2. The assembler might
  148. missleadingly claim you are trying to redefine labels in pass 2.
  149.  
  150. The listings show only the first two words of generated object code for
  151. each line. Do not be concerned if you want more than two words of data
  152. generated for a .word, .byte, .string, or one of the floating point
  153. formats that generates more than two words. The .dsk file will be fine
  154. even though the listing only shows the first two words. You can see the
  155. data in the .dsk file itself or you can examine the memory with the
  156. debugger. Perhaps I will fix this someday if I can figure out a nice
  157. way to do it.
  158.  
  159. A lot of the error messages are repeated the same on both passes.
  160.  
  161. Error messages in the listing file will generally PRECEDE the line they
  162. refer to.
  163.  
  164. "$ .set nnnn" is allowed but doesn't accomplish anything. The symbol
  165. "$" is reset to the current assmbly address for every line of the
  166. assembly. Using "$" as a label will produce lots of wierd error
  167. messages.
  168.  
  169. I make no effort to pass judgment on the severity of conditions
  170. detected. Error messages are not classified into warnings and fatals.
  171.  
  172. Lines skipped with .if can produce error messages while trying to
  173. decode opcode fields looking for .endif. .else or nested .ifs. This
  174. just means you should only use conditional assembly for actual code. To
  175. skip over comment blocks or other lines which should never be assembled
  176. use regular comment lines, not conditional assembly.
  177.  
  178. If you look at the structure of the assembler itself, you will find it
  179. is pretty straight forward. Pass_1 and pass_2 contain mainly a giant
  180. switch statement each based on the statement we are working on. There
  181. is lots of code duplicated which might better have been in common
  182. functions. This design resulted from seat-of-the-pants design while
  183. coding and edit mark block and copy, not from any deep conviction that
  184. it is right. The look up of the operation and the symbols are ultra
  185. simple linear searching. Hashing or sorting seemed like more trouble
  186. than they were worth. Tables have hard (but I think generous) limits
  187. that require editing the source and recompiling to change.
  188.  
  189. Lloyd Miller
  190. lloyd@lfmcal.cuc.ab.ca
  191. 1994 May 23 .. June 21
  192.